<?php
/**
 * Created by PhpStorm.
 * User: lili
 * Date: 2018/12/30
 * Time: 20:56
 */

namespace system\core\model;


class Model
{
    protected $table ;

    protected  $connection;


    public function __construct()
    {
        $this->connection = Connection::getInstance();
    }

    
    /*
     * 返回pdo 数据集合
     * 
     * 
     * */
    public function query($sql){
        $res = $this->connection->query($sql);
        return $res;
    }

    public function __call($name, $arguments)
    {
        // TODO: Implement __call() method.
        return call_user_func_array(array($this->connection,$name),$arguments );

    }


}